package com.eva.learn.concurrent.thinkInJava;

import java.util.concurrent.Callable;

/**
 * Callable接口实现任务完成后返回一个值
 * 
 * @author Evain.C
 *
 */
public class TaskWithResult implements Callable<String> {

	private int id;

	public TaskWithResult(int id) {
		this.id = id;
	}

	@Override
	public String call() throws Exception {
		return "return of TaskWithResult " + id;
	}

}
